﻿using System;
using System.Collections.Generic;
using System.ComponentModel;
using System.Drawing;
using System.Data;
using System.Linq;
using System.Text;
using System.Windows.Forms;
using SmartEP.Presenter;
using SmartEP.DTO;

namespace SmartDesktop
{
    public partial class FrameStub : UserControl,IFrameStub
    {
        private Frame _frame;
        private int _frameId;
        private string _frameImage;

        public FrameStub()
        {
            InitializeComponent();
        }

        public void ShowData(Frame frame)
        {
            if (frame != null)
            {
                this._frame = frame;
                lblFrameName.Text = Convert.ToString(_frame.FrameName);
                lblPrice.Text = Convert.ToString(_frame.FramePrice);
                _frameId = Convert.ToInt32(_frame.FrameId);
                _frameImage = Convert.ToString(_frame.FrameImage);
            }
        }

        public int FrameId
        {
            get { return _frameId; }
            set { _frameId = value; }
        }

        public String FrameName
        {
            get { return lblFrameName.Text; }
            set { lblFrameName.Text = value; }
        }

        public String FramePrice
        {
            get { return lblPrice.Text; }
            set { lblPrice.Text = value; }
        }

        public String FrameImage
        {
            get { return _frameImage; }
            set { _frameImage = value; }
        }

    }
}
